package com.kitchen.entity;

import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * 菜品实体类
 * 体现封装特性：私有属性 + 公共getter/setter方法
 */
public class Dish {
    private Integer dishId;
    private String dishName;
    private String dishType;
    private BigDecimal price;
    private Integer preparationTime;
    private String status;
    private LocalDateTime createTime;
    
    public Dish() {
    }
    
    public Dish(String dishName, String dishType, BigDecimal price, Integer preparationTime) {
        this.dishName = dishName;
        this.dishType = dishType;
        this.price = price;
        this.preparationTime = preparationTime;
        this.status = "可用";
    }
    
    // Getter和Setter方法
    public Integer getDishId() {
        return dishId;
    }
    
    public void setDishId(Integer dishId) {
        this.dishId = dishId;
    }
    
    public String getDishName() {
        return dishName;
    }
    
    public void setDishName(String dishName) {
        this.dishName = dishName;
    }
    
    public String getDishType() {
        return dishType;
    }
    
    public void setDishType(String dishType) {
        this.dishType = dishType;
    }
    
    public BigDecimal getPrice() {
        return price;
    }
    
    public void setPrice(BigDecimal price) {
        this.price = price;
    }
    
    public Integer getPreparationTime() {
        return preparationTime;
    }
    
    public void setPreparationTime(Integer preparationTime) {
        this.preparationTime = preparationTime;
    }
    
    public String getStatus() {
        return status;
    }
    
    public void setStatus(String status) {
        this.status = status;
    }
    
    public LocalDateTime getCreateTime() {
        return createTime;
    }
    
    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }
    
    @Override
    public String toString() {
        return "Dish{" +
                "dishId=" + dishId +
                ", dishName='" + dishName + '\'' +
                ", dishType='" + dishType + '\'' +
                ", price=" + price +
                ", preparationTime=" + preparationTime +
                ", status='" + status + '\'' +
                '}';
    }
}

